<%--
  Created by IntelliJ IDEA.
  User: zz
  Date: 2021/08/05
  Time: 上午 10:44:06
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java"  isELIgnored="false" %>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="js/jquery-1.11.3.js"></script>
    <link rel="stylesheet" href="css/login.css">
</head>
<body>
<form action="/login" method="post">
    <table>
        <tr>
            <td>
                账号：
            </td>
            <td>
                <input type="text" name="username"/>
            </td>
            <td>
                <span></span>
            </td>
        </tr>
        <tr>
            <td>
                密码：
            </td>
            <td>
                <input type="password" name="pwd"/>
            </td>
            <td>
                <span></span>
            </td>
        </tr>
        <tr>
            <td>
                验证码：
            </td>
            <td>
                <input type="text" name="code"/>
            </td>
            <td>
                <img src="/getCode" style="width: 100px; " alt="验证码" id="img">
            </td>
        </tr>
        <tr>
            <td colspan="3">
                <input type="submit" value="登录"/>
                <span style="color: red;">${msg}</span>
            </td>
        </tr>
    </table>
</form>
</body>
<script>
    $("#img").click(function () {
        $("#img").prop("src", "/getCode?date=" + new Date().getTime());
    })
</script>
</html>